import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/biz/roominfo/` + url, ...arg)

/**
 * 房间管理Api接口管理器
 *
 * @author jsy
 * @date  2024/09/16 23:14
 **/
export default {
	// 获取房间管理分页
	bizRoomInfoPage(data) {
		return request('page', data, 'get')
	},
	// 提交房间管理表单 edit为true时为编辑，默认为新增
	bizRoomInfoSubmitForm(data, edit = false) {
		return request(edit ? 'edit' : 'add', data)
	},
	// 删除房间管理
	bizRoomInfoDelete(data) {
		return request('delete', data)
	},
	// 获取房间管理详情
	bizRoomInfoDetail(data) {
		return request('detail', data, 'get')
	},
	// 获取楼宇下拉
	getBuildListList(data) {
		return request('getBuildListList', data, 'get')
	},
	//获取设备设施
	getEquipmentTypeList(data) {
		return request('getEquipmentTypeList', data, 'get')
	},

	//获取人员相关信息
	getUserList(data) {
		return request('getUserList', data, 'get')
	},
	//获取房间类型
	roomTypeList(data) {
		return request('roomTypeList', data, 'get')
	},
	//获取组织信息
	getOrgList(data) {
		return request('getOrgList', data, 'get')
	},
	bizRoomInfoExport(data) {
		return request('export', data, 'get', {
			responseType: 'blob'
		})
	}
}
